Skip to content

Remove deprecated repository attributes#39

Closed
johncblandii wants to merge 7 commits intomainfrom
feat/deprecate-has-downloads
Closed

Remove deprecated repository attributes#39
johncblandii wants to merge 7 commits intomainfrom
feat/deprecate-has-downloads

Conversation

@johncblandii
Copy link
Copy Markdown

@johncblandii johncblandii commented Apr 9, 2026

what

  • Remove three deprecated GitHub provider attributes from the repository variable: has_downloads, default_branch, and ignore_vulnerability_alerts_during_read
  • Update variable definitions, module configuration, test fixtures, test assertions, example defaults, and docs

why

references

Summary by CodeRabbit

  • Breaking Changes

    • Removed repository inputs: default_branch, has_downloads, and ignore_vulnerability_alerts_during_read — these options are no longer accepted.
  • Documentation

    • Updated repository input docs and examples to remove the deleted fields and reaffirm remaining defaults (e.g., enable_vulnerability_alerts).
  • Chores

    • Updated examples, fixtures, and tests to align with the revised repository schema.

The GitHub API has deprecated the has_downloads attribute for
repositories. Remove it from the variable definition, resource
configuration, test fixtures, and regenerate docs.
Copilot AI review requested due to automatic review settings April 9, 2026 17:26
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 9, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: cc86c716-68b9-4ccc-894b-6eebe260ac01

📥 Commits

Reviewing files that changed from the base of the PR and between 8b50200 and 5bb74b7.

📒 Files selected for processing (5)
  • README.md
  • src/README.md
  • src/main.tf
  • src/variables.tf
  • test/fixtures/stacks/catalog/usecase/import.yaml
💤 Files with no reviewable changes (3)
  • test/fixtures/stacks/catalog/usecase/import.yaml
  • src/variables.tf
  • src/main.tf
✅ Files skipped from review due to trivial changes (1)
  • src/README.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • README.md

📝 Walkthrough

Walkthrough

Removed three repository fields — default_branch, has_downloads, and ignore_vulnerability_alerts_during_read — from variable schema, module arguments, documentation, examples, fixtures, and tests. No other repository-related fields or behaviors were altered.

Changes

Cohort / File(s) Summary
Documentation
README.md, src/README.md, README.yaml
Removed default_branch and ignore_vulnerability_alerts_during_read from documented repository input schema and examples; adjusted surrounding schema blocks.
Variables & Module
src/variables.tf, src/main.tf
Deleted default_branch (and removed passing it to the repository module).
Examples & Defaults
examples/stacks/catalog/github/repo/defaults.yaml
Removed explicit default_branch, has_downloads, and ignore_vulnerability_alerts_during_read from repo defaults.
Test Fixtures & Tests
test/fixtures/stacks/catalog/usecase/basic.yaml, test/fixtures/stacks/catalog/usecase/import.yaml, test/fixtures/stacks/catalog/usecase/template.yaml, test/component_test.go
Updated fixtures and tests to drop inputs and assertions for default_branch, has_downloads, and ignore_vulnerability_alerts_during_read.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • Initial implementation #2 — Overlaps on removing/changing default_branch and related repository input fields.
  • Advanced Stack Examples #12 — Touches the same repository defaults and example fields (adds/removes default_branch and ignore_vulnerability_alerts_during_read).

Suggested labels

needs-test

Suggested reviewers

  • milldr
  • osterman

Poem

🐰 I hopped through files both near and far,
I nosed out three flags beneath the stars,
Docs and tests are lighter now,
A brisk little tidy — take a bow,
Carrots for all! 🥕

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and accurately summarizes the main change: removal of deprecated repository attributes. It is concise, specific, and directly related to the primary objective of the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/deprecate-has-downloads

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@mergify mergify Bot requested review from a team April 9, 2026 17:26
@mergify
Copy link
Copy Markdown

mergify Bot commented Apr 9, 2026

Important

Do not edit the README.md directly. It's auto-generated from the README.yaml

Please update the README.yaml file instead.

Could you fix it @johncblandii? 🙏

@mergify mergify Bot added triage Needs triage needs-test Needs testing labels Apr 9, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Removes support for the deprecated has_downloads repository attribute from this Terraform component’s input schema, wiring, and fixtures to align with the GitHub API deprecation.

Changes:

  • Dropped has_downloads from the repository input object type (src/variables.tf).
  • Removed has_downloads from the underlying repository module wiring (src/main.tf).
  • Updated generated READMEs and a test fixture to no longer reference has_downloads.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
test/fixtures/stacks/catalog/usecase/basic.yaml Removes has_downloads from a test fixture stack config.
src/variables.tf Removes has_downloads from the repository variable object type.
src/main.tf Stops passing has_downloads into the cloudposse/repository/github module.
src/README.md Regenerated docs to reflect the updated repository input type.
README.md Regenerated top-level docs to reflect the updated repository input type.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/variables.tf Outdated
Comment thread README.md Outdated
Comment thread src/README.md Outdated
@johncblandii johncblandii added the major Breaking changes (or first stable release) label Apr 9, 2026
@johncblandii
Copy link
Copy Markdown
Author

/terratest

…y_alerts_during_read

Both attributes are deprecated in the GitHub Terraform provider.
default_branch should use the github_branch_default resource instead,
and ignore_vulnerability_alerts_during_read is no longer needed as the
provider handles permissions automatically.
@johncblandii johncblandii changed the title Remove deprecated has_downloads support Remove deprecated repository attributes Apr 9, 2026
@mergify mergify Bot removed the needs-test Needs testing label Apr 17, 2026
@goruha
Copy link
Copy Markdown
Contributor

goruha commented Apr 18, 2026

@copilot resolve the merge conflicts in this pull request

Copy link
Copy Markdown

Copilot AI commented Apr 18, 2026

@copilot resolve the merge conflicts in this pull request

Resolved and merged main into this branch in commit 5bb74b7, fixing the README and src/README merge conflicts and preserving the deprecated-attribute removals.

Copilot AI requested a review from goruha April 18, 2026 14:27
@goruha
Copy link
Copy Markdown
Contributor

goruha commented Apr 18, 2026

@johncblandii I think we should leave default_branch due the replacement of resource should be done in module level

@goruha
Copy link
Copy Markdown
Contributor

goruha commented Apr 18, 2026

The other deprications are already merged.
I will close the PR.

Pls reopen if you think we need it

@goruha goruha closed this Apr 18, 2026
@mergify mergify Bot removed the triage Needs triage label Apr 18, 2026
@johncblandii
Copy link
Copy Markdown
Author

@johncblandii I think we should leave default_branch due the replacement of resource should be done in module level

But why leave a deprecated var?

github_branch_default is the right one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

major Breaking changes (or first stable release)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants